package cn.terminus.data.customer.contractrentdiscountclause.dao;

import cn.terminus.common.customer.bean.contractrentdiscountclause.dto.ContractRentDiscountClauseNewDto;
import cn.terminus.common.customer.bean.contractrentdiscountclause.dto.ContractRentDiscountClauseEditDto;
import cn.terminus.common.customer.bean.contractrentdiscountclause.dto.ContractRentDiscountClauseQueryDto;
import cn.terminus.common.customer.bean.contractrentdiscountclause.dto.ContractRentDiscountClauseDeleteDto;
import cn.terminus.common.customer.bean.contractrentdiscountclause.dto.ContractRentDiscountClauseGetsDto;
import cn.terminus.common.customer.bean.contractrentdiscountclause.dto.ContractRentDiscountClauseResultDto;
import cn.terminus.result.common.page.TerminusPageAble;
import cn.terminus.result.common.page.TerminusPageInfo;

import java.util.List;

/**
 * 合同优惠条款(ContractRentDiscountClause)表服务接口
 *
 * @author makejava
 * @since 2021-07-21 11:15:29
 */
public interface ContractRentDiscountClauseDao {

    /**
     * 新增
     *
     * @param dto
     * @return
     */
    Integer add(ContractRentDiscountClauseNewDto dto);

    /**
     * 更新
     *
     * @param dto
     * @return
     */
    Integer update(ContractRentDiscountClauseEditDto dto);


    /**
     * gets
     *
     * @param dto
     * @return
     */
    List<ContractRentDiscountClauseResultDto> gets(ContractRentDiscountClauseGetsDto dto);

    /**
     * 删除
     *
     * @param dto
     * @return
     */
    Integer delete(ContractRentDiscountClauseDeleteDto dto);

    /**
     * 查询
     *
     * @param dto
     * @return
     */
    List<ContractRentDiscountClauseResultDto> query(ContractRentDiscountClauseQueryDto dto);

    /**
     * 分页查询
     *
     * @param dto
     * @param page
     * @return
     */
    TerminusPageAble<ContractRentDiscountClauseResultDto> page(ContractRentDiscountClauseQueryDto dto, TerminusPageInfo page);

    Integer insertBatch(List<ContractRentDiscountClauseNewDto> dtos);

    Integer deleteWithContractId(Long id);
}
